.class Les/xy$x0;
.super Ljava/lang/Object;
.source "EditMenuItemProvider.java"

# interfaces
.implements Landroid/view/MenuItem$OnMenuItemClickListener;


# annotations
.annotation system Ldalvik/annotation/EnclosingMethod;
    value = Les/xy;->d()V
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x0
    name = null
.end annotation


# instance fields
.field final synthetic a:Les/xy;


# direct methods
.method constructor <init>(Les/xy;)V
    .locals 0

    .line 1
    iput-object p1, p0, Les/xy$x0;->a:Les/xy;

    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    return-void
.end method


# virtual methods
.method public onMenuItemClick(Landroid/view/MenuItem;)Z
    .locals 10

    .line 1
    iget-object p1, p0, Les/xy$x0;->a:Les/xy;

    invoke-static {p1}, Les/xy;->b(Les/xy;)Ljava/util/List;

    move-result-object p1

    invoke-interface {p1}, Ljava/util/List;->size()I

    move-result p1

    const/4 v0, 0x0

    const/4 v1, 0x1

    if-nez p1, :cond_0

    .line 2
    iget-object p1, p0, Les/xy$x0;->a:Les/xy;

    invoke-static {p1}, Les/xy;->a(Les/xy;)Lcom/estrongs/android/pop/view/FileExplorerActivity;

    move-result-object p1

    invoke-virtual {p1}, Landroid/app/Activity;->getBaseContext()Landroid/content/Context;

    move-result-object p1

    const v2, 0x7f1104a3

    invoke-static {p1, v2, v0}, Lcom/estrongs/android/ui/view/d;->a(Landroid/content/Context;II)V

    goto/16 :goto_1

    .line 3
    :cond_0
    iget-object p1, p0, Les/xy$x0;->a:Les/xy;

    invoke-static {p1}, Les/xy;->b(Les/xy;)Ljava/util/List;

    move-result-object p1

    invoke-interface {p1}, Ljava/util/List;->size()I

    move-result p1

    if-ne p1, v1, :cond_4

    .line 4
    iget-object p1, p0, Les/xy$x0;->a:Les/xy;

    invoke-static {p1}, Les/xy;->b(Les/xy;)Ljava/util/List;

    move-result-object p1

    invoke-interface {p1, v0}, Ljava/util/List;->get(I)Ljava/lang/Object;

    move-result-object p1

    check-cast p1, Lcom/estrongs/fs/g;

    invoke-interface {p1}, Lcom/estrongs/fs/g;->d()Ljava/lang/String;

    move-result-object p1

    .line 5
    new-instance v9, Lcom/estrongs/android/pop/app/compress/a;

    iget-object v2, p0, Les/xy$x0;->a:Les/xy;

    invoke-static {v2}, Les/xy;->a(Les/xy;)Lcom/estrongs/android/pop/view/FileExplorerActivity;

    move-result-object v3

    const/4 v4, 0x0

    const/4 v6, 0x0

    const/4 v7, 0x0

    const/4 v8, 0x0

    move-object v2, v9

    move-object v5, p1

    invoke-direct/range {v2 .. v8}, Lcom/estrongs/android/pop/app/compress/a;-><init>(Landroid/content/Context;ZLjava/lang/String;Ljava/lang/String;Ljava/util/List;Lcom/estrongs/android/pop/app/compress/a$f;)V

    .line 6
    invoke-virtual {p1}, Ljava/lang/String;->toLowerCase()Ljava/lang/String;

    move-result-object p1

    const-string v2, ".apk"

    .line 7
    invoke-virtual {p1, v2}, Ljava/lang/String;->endsWith(Ljava/lang/String;)Z

    move-result p1

    if-eqz p1, :cond_1

    .line 8
    invoke-virtual {v9, v1}, Lcom/estrongs/android/pop/app/compress/a;->a(Z)V

    const/4 v0, 0x1

    .line 9
    :cond_1
    iget-object p1, p0, Les/xy$x0;->a:Les/xy;

    invoke-static {p1}, Les/xy;->a(Les/xy;)Lcom/estrongs/android/pop/view/FileExplorerActivity;

    move-result-object p1

    invoke-virtual {p1}, Lcom/estrongs/android/pop/view/FileExplorerActivity;->Z()Lcom/estrongs/android/view/FileGridViewWrapper;

    move-result-object p1

    .line 10
    instance-of p1, p1, Lcom/estrongs/android/view/CompressGridViewWrapper;

    if-nez p1, :cond_2

    .line 11
    invoke-virtual {v9, v1}, Lcom/estrongs/android/pop/app/compress/a;->a(Z)V

    .line 12
    :cond_2
    invoke-virtual {v9}, Lcom/estrongs/android/pop/app/compress/a;->b()V

    .line 13
    iget-object p1, p0, Les/xy$x0;->a:Les/xy;

    invoke-static {p1}, Les/xy;->a(Les/xy;)Lcom/estrongs/android/pop/view/FileExplorerActivity;

    move-result-object p1

    invoke-virtual {p1}, Lcom/estrongs/android/pop/view/FileExplorerActivity;->R()V

    .line 14
    :try_start_0
    new-instance p1, Lorg/json/JSONObject;

    invoke-direct {p1}, Lorg/json/JSONObject;-><init>()V

    if-eqz v0, :cond_3

    const/4 v0, 0x6

    .line 15
    invoke-static {v0}, Ljava/lang/String;->valueOf(I)Ljava/lang/String;

    move-result-object v0

    goto :goto_0

    :cond_3
    const/4 v0, 0x5

    invoke-static {v0}, Ljava/lang/String;->valueOf(I)Ljava/lang/String;

    move-result-object v0
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_1

    .line 16
    :goto_0
    :try_start_1
    invoke-virtual {p1, v0, v1}, Lorg/json/JSONObject;->put(Ljava/lang/String;I)Lorg/json/JSONObject;
    :try_end_1
    .catch Lorg/json/JSONException; {:try_start_1 .. :try_end_1} :catch_0
    .catch Ljava/lang/Exception; {:try_start_1 .. :try_end_1} :catch_1

    .line 17
    :catch_0
    :try_start_2
    iget-object v0, p0, Les/xy$x0;->a:Les/xy;

    invoke-static {v0}, Les/xy;->a(Les/xy;)Lcom/estrongs/android/pop/view/FileExplorerActivity;

    move-result-object v0

    invoke-virtual {v0}, Lcom/estrongs/android/pop/view/FileExplorerActivity;->b0()Ljava/lang/String;

    move-result-object v0

    invoke-static {v0}, Lcom/estrongs/android/statistics/c;->a(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v3

    const-string v2, "extract_to_c"

    .line 18
    invoke-virtual {p1}, Lorg/json/JSONObject;->toString()Ljava/lang/String;

    move-result-object v4

    const/4 v5, 0x1

    const-wide/16 v6, 0x0

    const/4 v8, 0x0

    .line 19
    invoke-static/range {v2 .. v8}, Lcom/estrongs/android/pop/utils/p;->a(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;ZJI)V
    :try_end_2
    .catch Ljava/lang/Exception; {:try_start_2 .. :try_end_2} :catch_1

    goto :goto_1

    :catch_1
    move-exception p1

    .line 20
    invoke-virtual {p1}, Ljava/lang/Exception;->printStackTrace()V

    :cond_4
    :goto_1
    return v1
.end method
